<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<!--#include file="../../../inc/conn.asp"-->
<!--#include file="../../../inc/function.asp"-->
<%const link="auctions"


'读取产品
AuctionID=checkstr(inHTML(request("id")))
Set myCache = new Cache
myCache.name="auctions"&AuctionID '定义缓存名称 
if myCache.valid then '如果缓存有效
	shoppingproduct=myCache.value '读取缓存内容
else
    responsegroup="large"
	image_size=600
	topurl="http://auctions.yahooapis.jp/AuctionWebService/V2/auctionItem?"'正式接口
	postdatastr="appid="&yahoo_daigou_apiid&"&responsegroup="&responsegroup&"&auctionID="&AuctionID&"&image_size="&image_size&""
	REST_RESPONSEhot=getHTTPPage(topurl&postdatastr) 
	shoppingproduct=REST_RESPONSEhot
    myCache.add shoppingproduct,dateadd("n",1440*web_cache,now) '将内容赋值给缓存，并设置缓存有效期是当前时间＋1000分钟 
end if
'Response.Write(yahoodaigouproduct)
myCache.makeEmpty()  
set clsCache=nothing '释放对象

	Set xml=Server.CreateObject("Microsoft.XMLDOM")
	xml.Async=False 
	xml.ValidateOnParse=False 
	xml.LoadXml(shoppingproduct) 
	Set item = xml.selectNodes("ResultSet")
	For i = 0 To iLength
	Set oXMLItem = item.item(i)
	if instr(shoppingproduct,"totalResultsReturned")>0 then totalResultsAvailable=oXMLItem.getAttribute("totalResultsReturned") else totalResultsAvailable=0
	Next
	
	if totalResultsAvailable="1" then
	  Set item=xml.getElementsByTagName("Result") 
	  For a=0 To (item.Length-1) 
	  '类别ID 
	  Set CategoryID=item.Item(a).getElementsByTagName("CategoryID") 
	  set CategoryIDNode = item.Item(a).selectSingleNode("CategoryID")  
	  if Not CategoryIDNode is Nothing Then CategoryID=CategoryID.Item(0).Text else CategoryID=""
	  '产品名称 
	  Set Title=item.Item(a).getElementsByTagName("Title") 
	  set TitleNode = item.Item(a).selectSingleNode("Title")  
	  if Not TitleNode is Nothing Then Title=Title.Item(0).Text else Title=""  
	  '产品图片1 
	  Set Image1=item.Item(a).getElementsByTagName("Img/Image1") 
	  set Image1Node = item.Item(a).selectSingleNode("Img/Image1")  
	  if Not Image1Node is Nothing Then Image1=Image1.Item(0).Text else Image1=""  
	  '产品组图
	  Set Img=item.Item(a).getElementsByTagName("Img") 
	  set ImgNode = item.Item(a).selectSingleNode("Img")  
	  if Not ImgNode is Nothing Then Img=Img.Item(0).Text else Img=""   
	  '商品链接 
	  Set AuctionItemUrl=item.Item(a).getElementsByTagName("AuctionItemUrl") 
	  set AuctionItemUrlNode = item.Item(a).selectSingleNode("AuctionItemUrl")  
	  if Not AuctionItemUrlNode is Nothing Then AuctionItemUrl=AuctionItemUrl.Item(0).Text else AuctionItemUrl="" 
	  '商品描述 
	  Set Description=item.Item(a).getElementsByTagName("Description") 
	  set DescriptionNode = item.Item(a).selectSingleNode("Description")  
	  if Not DescriptionNode is Nothing Then Description=Description.Item(0).Text else Description="" 
	  '商品起始价格 
	  Set Initprice=item.Item(a).getElementsByTagName("Initprice") 
	  set InitpriceNode = item.Item(a).selectSingleNode("Initprice")  
	  if Not InitpriceNode is Nothing Then Initprice=Initprice.Item(0).Text else Initprice=""  
	  '商品现在价格 
	  Set Price=item.Item(a).getElementsByTagName("Price") 
	  set PriceNode = item.Item(a).selectSingleNode("Price")  
	  if Not PriceNode is Nothing Then Price=Price.Item(0).Text else Price="" 
	  '商品数量 
	  Set Quantity=item.Item(a).getElementsByTagName("Quantity") 
	  set QuantityNode = item.Item(a).selectSingleNode("Quantity")  
	  if Not QuantityNode is Nothing Then Quantity=Quantity.Item(0).Text else Quantity="" 
	  '商品出价次数 
	  Set Bids=item.Item(a).getElementsByTagName("Bids") 
	  set BidsNode = item.Item(a).selectSingleNode("Bids")  
	  if Not BidsNode is Nothing Then Bids=Bids.Item(0).Text else Bids="0" 
	  '商品是否二手 
	  Set Condition=item.Item(a).getElementsByTagName("ItemStatus/Condition") 
	  set ConditionNode = item.Item(a).selectSingleNode("ItemStatus/Condition")  
	  if Not ConditionNode is Nothing Then Condition=Condition.Item(0).Text else Condition="" 
	  '商品是否二手说明 
	  Set Comment=item.Item(a).getElementsByTagName("ItemStatus/Comment") 
	  set CommentNode = item.Item(a).selectSingleNode("ItemStatus/Comment")  
	  if Not CommentNode is Nothing Then Comment=Comment.Item(0).Text else Comment="" 
	  '开始时间 
	  Set StartTime=item.Item(a).getElementsByTagName("StartTime") 
	  set StartTimeNode = item.Item(a).selectSingleNode("StartTime")  
	  if Not StartTimeNode is Nothing Then StartTime=StartTime.Item(0).Text else StartTime="" 
	  '结束时间 
	  Set EndTime=item.Item(a).getElementsByTagName("EndTime") 
	  set EndTimeNode = item.Item(a).selectSingleNode("EndTime")  
	  if Not EndTimeNode is Nothing Then EndTime=EndTime.Item(0).Text else EndTime="" 
	  '即决价格 
	  Set Bidorbuy=item.Item(a).getElementsByTagName("Bidorbuy") 
	  set BidorbuyNode = item.Item(a).selectSingleNode("Bidorbuy")  
	  if Not BidorbuyNode is Nothing Then Bidorbuy=Bidorbuy.Item(0).Text else Bidorbuy="" 
	  '税率 
	  Set TaxRate=item.Item(a).getElementsByTagName("TaxRate") 
	  set TaxRateNode = item.Item(a).selectSingleNode("TaxRate")  
	  if Not TaxRateNode is Nothing Then TaxRate=TaxRate.Item(0).Text else TaxRate=""
	  '是否信用限制 
	  Set IsBidCreditRestrictions=item.Item(a).getElementsByTagName("IsBidCreditRestrictions") 
	  set IsBidCreditRestrictionsNode = item.Item(a).selectSingleNode("IsBidCreditRestrictions")  
	  if Not IsBidCreditRestrictionsNode is Nothing Then IsBidCreditRestrictions=IsBidCreditRestrictions.Item(0).Text else IsBidCreditRestrictions=""
	  '是否投标人限制 
	  Set IsBidderRestrictions=item.Item(a).getElementsByTagName("IsBidderRestrictions") 
	  set IsBidderRestrictionsNode = item.Item(a).selectSingleNode("IsBidderRestrictions")  
	  if Not IsBidderRestrictionsNode is Nothing Then IsBidderRestrictions=IsBidderRestrictions.Item(0).Text else IsBidderRestrictions=""
	  '是否投标人比率限制 
	  Set IsBidderRatioRestrictions=item.Item(a).getElementsByTagName("IsBidderRatioRestrictions") 
	  set IsBidderRatioRestrictionsNode = item.Item(a).selectSingleNode("IsBidderRatioRestrictions")  
	  if Not IsBidderRatioRestrictionsNode is Nothing Then IsBidderRatioRestrictions=IsBidderRatioRestrictions.Item(0).Text else IsBidderRatioRestrictions=""
	  '是否提前结标
	  Set IsEarlyClosing=item.Item(a).getElementsByTagName("IsEarlyClosing") 
	  set IsEarlyClosingNode = item.Item(a).selectSingleNode("IsEarlyClosing")  
	  if Not IsEarlyClosingNode is Nothing Then IsEarlyClosing=IsEarlyClosing.Item(0).Text else IsEarlyClosing=""
	  '是否延长
	  Set IsAutomaticExtension=item.Item(a).getElementsByTagName("IsAutomaticExtension") 
	  set IsAutomaticExtensionNode = item.Item(a).selectSingleNode("IsAutomaticExtension")  
	  if Not IsAutomaticExtensionNode is Nothing Then IsAutomaticExtension=IsAutomaticExtension.Item(0).Text else IsAutomaticExtension=""
	  '是否退货
	  Set IsOffer=item.Item(a).getElementsByTagName("IsOffer") 
	  set IsOfferNode = item.Item(a).selectSingleNode("IsOffer")  
	  if Not IsOfferNode is Nothing Then IsOffer=IsOffer.Item(0).Text else IsOffer=""
	  '是否慈善
	  Set IsCharity=item.Item(a).getElementsByTagName("IsCharity") 
	  set IsCharityNode = item.Item(a).selectSingleNode("IsCharity")  
	  if Not IsCharityNode is Nothing Then IsCharity=IsCharity.Item(0).Text else IsCharity=""
	  '是否支持信用卡付款
	  Set IsCreditCard=item.Item(a).getElementsByTagName("Payment/EasyPayment/IsCreditCard") 
	  set IsCreditCardNode = item.Item(a).selectSingleNode("Payment/EasyPayment/IsCreditCard")  
	  if Not IsCreditCardNode is Nothing Then IsCreditCard=IsCreditCard.Item(0).Text else IsCreditCard=""
	  '是否网银转账
	  Set IsNetBank=item.Item(a).getElementsByTagName("Payment/EasyPayment/IsNetBank") 
	  set IsNetBankNode = item.Item(a).selectSingleNode("Payment/EasyPayment/IsNetBank")  
	  if Not IsNetBankNode is Nothing Then IsNetBank=IsNetBank.Item(0).Text else IsNetBank=""
	  '付款银行信息
	  Set Bank=item.Item(a).getElementsByTagName("Payment/Bank") 
	  set BankNode = item.Item(a).selectSingleNode("Payment/Bank")  
	  if Not BankNode is Nothing Then Bank=Bank.Item(0).Text else Bank=""
	  '==业务
	  Set BlindBusiness=item.Item(a).getElementsByTagName("BlindBusiness") 
	  set BlindBusinessNode = item.Item(a).selectSingleNode("BlindBusiness")  
	  if Not BlindBusinessNode is Nothing Then BlindBusiness=BlindBusiness.Item(0).Text else BlindBusiness=""
	  '==7:11 上午收到
	  Set SevenElevenReceive=item.Item(a).getElementsByTagName("SevenElevenReceive") 
	  set SevenElevenReceiveNode = item.Item(a).selectSingleNode("SevenElevenReceive")  
	  if Not SevenElevenReceiveNode is Nothing Then SevenElevenReceive=SevenElevenReceive.Item(0).Text else SevenElevenReceive=""
	  '航运费
	  Set ChargeForShipping=item.Item(a).getElementsByTagName("ChargeForShipping") 
	  set ChargeForShippingNode = item.Item(a).selectSingleNode("ChargeForShipping")  
	  if Not ChargeForShippingNode is Nothing Then ChargeForShipping=ChargeForShipping.Item(0).Text else ChargeForShipping=""
	  '地区
	  Set Location=item.Item(a).getElementsByTagName("Location") 
	  set LocationNode = item.Item(a).selectSingleNode("Location")  
	  if Not LocationNode is Nothing Then Location=Location.Item(0).Text else Location=""
	  '全世界
	  Set IsWorldwide=item.Item(a).getElementsByTagName("IsWorldwide") 
	  set IsWorldwideNode = item.Item(a).selectSingleNode("IsWorldwide")  
	  if Not IsWorldwideNode is Nothing Then IsWorldwide=IsWorldwide.Item(0).Text else IsWorldwide=""
	  '船运时间
	  Set ShipTime=item.Item(a).getElementsByTagName("ShipTime") 
	  set ShipTimeNode = item.Item(a).selectSingleNode("ShipTime")  
	  if Not ShipTimeNode is Nothing Then ShipTime=ShipTime.Item(0).Text else ShipTime=""
	  '属性-尺码
	  Set Size=item.Item(a).getElementsByTagName("BaggageInfo/Size") 
	  set SizeNode = item.Item(a).selectSingleNode("BaggageInfo/Size")  
	  if Not SizeNode is Nothing Then Size=Size.Item(0).Text else Size=""
	  '属性-重量
	  Set Weight=item.Item(a).getElementsByTagName("BaggageInfo/Weight") 
	  set WeightNode = item.Item(a).selectSingleNode("BaggageInfo/Weight")  
	  if Not WeightNode is Nothing Then Weight=Weight.Item(0).Text else Weight=""
	  '成人
	  Set IsAdult=item.Item(a).getElementsByTagName("IsAdult") 
	  set IsAdultNode = item.Item(a).selectSingleNode("IsAdult")  
	  if Not IsAdultNode is Nothing Then IsAdult=IsAdult.Item(0).Text else IsAdult=""
	  '慈善选项
	  Set Proportion=item.Item(a).getElementsByTagName("CharityOption/Proportion") 
	  set ProportionNode = item.Item(a).selectSingleNode("CharityOption/Proportion")  
	  if Not ProportionNode is Nothing Then Proportion=Proportion.Item(0).Text else Proportion=""
	  '卖家ID 
	  Set SellerID=item.Item(a).getElementsByTagName("Seller/Id") 
	  set SellerIDNode = item.Item(a).selectSingleNode("Seller/Id")  
	  if Not SellerIDNode is Nothing Then SellerID=SellerID.Item(0).Text else SellerID="" 
	  '===== 
	  Set ItemListURL=item.Item(a).getElementsByTagName("Seller/ItemListURL") 
	  set ItemListURLNode = item.Item(a).selectSingleNode("Seller/ItemListURL")  
	  if Not ItemListURLNode is Nothing Then ItemListURL=ItemListURL.Item(0).Text else ItemListURL="" 
	  '=====卖家评价链接 
	  Set RatingURL=item.Item(a).getElementsByTagName("Seller/RatingURL") 
	  set RatingURLNode = item.Item(a).selectSingleNode("Seller/RatingURL")  
	  if Not RatingURLNode is Nothing Then RatingURL=RatingURL.Item(0).Text else RatingURL="" 
	  '卖家总好评 
	  Set TotalGoodRating=item.Item(a).getElementsByTagName("Seller/Rating/TotalGoodRating") 
	  set TotalGoodRatingNode = item.Item(a).selectSingleNode("Seller/Rating/TotalGoodRating")  
	  if Not TotalGoodRatingNode is Nothing Then TotalGoodRating=TotalGoodRating.Item(0).Text else TotalGoodRating="" 
	  '卖家总差评 
	  Set TotalBadRating=item.Item(a).getElementsByTagName("Seller/Rating/TotalBadRating") 
	  set TotalBadRatingNode = item.Item(a).selectSingleNode("Seller/Rating/TotalBadRating")  
	  if Not TotalBadRatingNode is Nothing Then TotalBadRating=TotalBadRating.Item(0).Text else TotalBadRating="" 
	  '卖家账户是否被暂停 
	  Set IsSuspended=item.Item(a).getElementsByTagName("Seller/Rating/IsSuspended") 
	  set IsSuspendedNode = item.Item(a).selectSingleNode("Seller/Rating/IsSuspended")  
	  if Not IsSuspendedNode is Nothing Then IsSuspended=IsSuspended.Item(0).Text else IsSuspended="" 
	  '卖家账户是否被删除 
	  Set IsDeleted=item.Item(a).getElementsByTagName("Seller/Rating/IsDeleted") 
	  set IsDeletedNode = item.Item(a).selectSingleNode("Seller/Rating/IsDeleted")  
	  if Not IsDeletedNode is Nothing Then IsDeleted=IsDeleted.Item(0).Text else IsDeleted="" 
	  '最高出价者 
	  Set BidderID=item.Item(a).getElementsByTagName("HighestBidders/Bidder/Id") 
	  set BidderIDNode = item.Item(a).selectSingleNode("HighestBidders/Bidder/Id")  
	  if Not BidderIDNode is Nothing Then BidderID=BidderID.Item(0).Text else BidderID="" 
	  next  
	
	'获取出价金额
	 if Bids<>"0" then
	     if Quantity=1 then 
	       if price=>1 and price<1000 then
		     BidderPriceMoney=10
		   elseif price=>1000 and price<5000 then
		     BidderPriceMoney=100
		   elseif price=>5000 and price<10000 then
		     BidderPriceMoney=250
		   elseif price=>10000 and price<50000 then
		     BidderPriceMoney=500
		   elseif price=>50000 then
		     BidderPriceMoney=1000
		   end if
		 elseif Quantity>1 and CINT(cdbl(Bids)/cdbl(Quantity))=cdbl(Bids)/cdbl(Quantity) then
		   if price=>1 and price<1000 then
		     BidderPriceMoney=10
		   elseif price=>1000 and price<5000 then
		     BidderPriceMoney=100
		   elseif price=>5000 and price<10000 then
		     BidderPriceMoney=250
		   elseif price=>10000 and price<50000 then
		     BidderPriceMoney=500
		   elseif price=>50000 then
		     BidderPriceMoney=1000
		   end if
		 end if
	 end if
	 if BidderPriceMoney="" then BidderPriceMoney=0
	
	
	    '出价记录
		Set myCache = new Cache
		myCache.name="Bidderdetail"&AuctionID '定义缓存名称 
		if myCache.valid then '如果缓存有效
			Bidderdetail=myCache.value '读取缓存内容
		else
			topurl="http://auctions.yahooapis.jp/AuctionWebService/V1/BidHistoryDetail?"
			postdatastr="appid="&yahoo_daigou_apiid&"&auctionID="&AuctionID&""
			REST_RESPONSEhotx=getHTTPPage(topurl&postdatastr) 
			Bidderdetail=REST_RESPONSEhotx
			myCache.add Bidderdetail,dateadd("n",1440*web_cache,now) '将内容赋值给缓存，并设置缓存有效期是当前时间＋1000分钟 
		end if
		'Response.Write(Bidderdetail)
		myCache.makeEmpty()  
		set clsCache=nothing '释放对象
		
			Set xml=Server.CreateObject("Microsoft.XMLDOM")
			xml.Async=False 
			xml.ValidateOnParse=False 
			xml.LoadXml(Bidderdetail) 
		
			Set item = xml.selectNodes("ResultSet")
			For i = 0 To iLength
			Set oXMLItem = item.item(i)
			firstResultPosition=oXMLItem.getAttribute("firstResultPosition")
			Next
			
			if firstResultPosition="0" then
			  Bidderlist= "<dl>暂无出价</dl>"
			else
			  Set item=xml.getElementsByTagName("Result") 
			  For a=0 To (item.Length-1) 
			  '竞拍者 
			  Set Bidder=item.Item(a).getElementsByTagName("Bidder") 
			  set BidderNode = item.Item(a).selectSingleNode("Bidder")  
			  if Not BidderNode is Nothing Then Bidder=Bidder.Item(0).Text else Bidder=""
			  '出价 
			  Set BidderPrice=item.Item(a).getElementsByTagName("Price") 
			  set BidderPriceNode = item.Item(a).selectSingleNode("Price")  
			  if Not BidderPriceNode is Nothing Then BidderPrice=BidderPrice.Item(0).Text else BidderPrice=""  
			  '数量 
			  Set BidderQuantity=item.Item(a).getElementsByTagName("Quantity") 
			  set BidderQuantityNode = item.Item(a).selectSingleNode("Quantity")  
			  if Not BidderQuantityNode is Nothing Then BidderQuantity=BidderQuantity.Item(0).Text else BidderQuantity="系统自动出价"  
			  '时间 
			  Set BidderDate=item.Item(a).getElementsByTagName("Date") 
			  set BidderDateNode = item.Item(a).selectSingleNode("Date")  
			  if Not BidderDateNode is Nothing Then BidderDate=BidderDate.Item(0).Text else BidderDate="" 
		
			  Bidderlist=Bidderlist+ "<dl><dt><strong>出价者：</strong> "&Bidder&"</dt><dd>出价："&BidderPrice&"日元 ， 数量："&BidderQuantity&" ， 时间："&dateadd("h",-1,replace(replace(BidderDate,"+09:00",""),"T"," "))&"</dd></dl>"
			  next  
			end if
	
	
	end if


%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><%=Title%></title>
<meta name="keywords" content="<%=Title%>" />
<meta name="description" content="<%=Title%>" />
<link href="favicon.ico" rel="shortcut icon" type="image/x-icon"/>
<link rel="stylesheet" type="text/css" href="/css/style.css" />
<script type="text/javascript" src="/js/jquery.min.js"></script>
<script type="text/javascript" src="/js/jquery.tabs.js"></script>
<script src="/js/pro_pic.js" type="text/javascript"></script>
<script type="text/javascript">

$(document).ready(function(){
    jQuery.focusblur = function(focusid) {
		var focusblurid = $(focusid);
		var defval = focusblurid.val();
		
        focusblurid.focus(function(){
			$("#select_key").toggle();
        });
        focusblurid.blur(function(){
			
        });
        
    };
    $.focusblur("#search_2");
	$("#select_key dd").click(function () {
		$('#search_2').val($(this).html());
		$("#select_key").hide();
	});
	
});



$(function(){
	$('.show_s_1').Tabs({
		event:'click'
	});
	$('.show_s_2').Tabs({
		event:'click'
	});
	$('.reg_s_1').Tabs({
		event:'click'
	});
});	
</script>
<script type="text/javascript">
$(document).ready(function(){ 
	$('#select_1').change(function(){ 
		$('#search_1').val($(this).find("option:selected").text());
	});
}); 
$(function (){
  $(".main_class_li").hover(function(){
	$(".child_class",this).show();
  });
  $(".main_class_li").mouseleave(function(){
	$(".child_class",this).hide();
  });
});
</script>
<script>
$(function(){
	$(".ftoollist li").hover(function(){
			var $this = $(this);
			$this.addClass("on").siblings().removeClass("on");
			var $preNumber = $this.index();
			$(".fimglist li").removeClass("onpre");
			$(".fimglist li:eq($preNumber)").addClass("onpre");
			var distance = 602;
			distance = distance * $preNumber; 
			distance = distance * -1;
			$(".fimglist").stop().animate({marginLeft: distance + "px"}, {duration: 500});
	});
});
</script>
</head>
<body>

<!--#include file="../../common/topauctions.asp"-->


<%
if totalResultsAvailable="0" then
  response.Write "<div class=""brand-list"" id=""brand-waterfall"" style='text-align:center;height:150px'>产品不存在 <a href='javascript:history.go(-1);'>返回上一页</a></div>"
else
  '读取路径
  typelink_id=CategoryID
  For s=1 to 6
	  set rss=conn.execute("select fid,id,title,CategoryId,ParentCategoryId from auctions where CategoryId='"&typelink_id&"'")
	  if not rss.eof then
		 typelink_id=rss("ParentCategoryId")
		 typelink=" > <a href='/auctions/"&rss("CategoryId")&"?s=t'>"&rss("title")&"</a>"+typelink
	  set rss=nothing
	  end if
  Next
%>




<div class="fullwidth bg2">
	<div class="place ">
		<a href="/">首页</a> &gt; <a href="/auctions">我要代拍</a> <%=typelink%> &gt; <%=Title%>
	</div>
</div>
<div class="clear20"></div>
<!--main-->
<div class="fullwidth bg1">
	<div class="main">
		<div class="pro_d_l">
			<div class="pro_pic">
				<div class="ro_pic">
					<div class="box-lanrenzhijia">
						<div id="bigpicarea">
						<p class="bigbtnPrev"><span id="big_play_prev"></span></p>
						
                        
                        
                        <div id="image_xixi-01" class="image" style="opacity: 1; display: block; ">
							<a><img src="<%=Image1%>"></a>
							<div class="word" style="display: block;"></div>
						</div>

                        
                        
                        <%
						ImgI=split(Img," ")
						for i=2 to ubound(ImgI)
						%>
                        <div id="image_xixi-0<%=i%>" class="image" style="opacity: 0; display: none; ">
							<a><img src="<%=ImgI(i)%>"></a>
							<div class="word" style="display: block;"></div>
						</div>
                        <%
						imgsc=imgsc+", ""xixi-0"&i&""""
						imglist=imglist+"<li><a id='thumb_xixi-0"&i&"'><img src='"&ImgI(i)&"' width='50' height='50'></a></li>"
						next%>

						<p class="bigbtnNext"><span id="big_play_next"></span></p>
					</div>
					<div id="smallpicarea">
						<div id="thumbs">
							<ul>
                            
                            <li><a id='thumb_xixi-01' class='current'><img src='<%=Image1%>' width='50' height='50'></a></li>
                            <%=imglist%>

							</ul>
						</div>
					</div>
					<script type="text/javascript">
						var target = ["xixi-01"<%=imgsc%>];
					</script>
					</div>
				</div>
			</div>
			<form action="" name="form" method="post">
            <div class="pro_info">
				<dl>
                    <dd><span class="span_l">拍卖号：</span><%=AuctionID%> </dd>
                    <dd><span class="span_l">起拍价格：</span><%=Initprice%>日元</dd>
                    <dd><span class="span_l">当前出价：</span><font class="red"><%=Price%>日元</font></dd>
                    <%if Bidorbuy<>"" then response.Write "<dd><span class=""span_l"">一口价：</span>"&Price&"日元</dd>"%>
					<dd><span class="span_l">开始时间：</span><%=dateadd("h",-1,replace(replace(StartTime,"+09:00",""),"T"," "))%>  </dd>
					<dd><span class="span_l">个数：</span><font class="red"><%=Quantity%></font> </dd>
					<dd><span class="span_l">结束时间：</span><%=dateadd("h",-1,replace(replace(EndTime,"+09:00",""),"T"," "))%>  </dd>
					<dd><span class="span_l">最高出价者：</span><font class="red"><%if BidderID="" then response.Write "无" else response.Write BidderID%></font> </dd>
                    <dd><span class="span_l">出价次数：</span><font class="red"><%=Bids%></font> </dd>
					<dd><span class="span_l">提前结束：</span><%if IsEarlyClosing="true" then response.Write "有可能" else response.Write "不可能"%>  </dd>
					<dd><span class="span_l">自动延长：</span><%if IsAutomaticExtension="true" then response.Write "会" else response.Write "不会"%>   </dd>
					<dd><span class="span_l">日本邮费：</span><%if IsCharity="true" then response.Write "卖家承担" else response.Write "得标者承担"%>  </dd>
					<dd><span class="span_l">可否退货：</span><font class="red"><%if IsOffer="true" then response.Write "可以" else response.Write "不可以"%></font>  </dd>
                    <dd><span class="span_l">商品成色：</span><font class="red"><%if Condition="new" then response.Write "全新" else response.Write "二手" &" " &Comment%></font>  </dd>
				</dl>
				<div class="clear20"></div>
				<ul>
					<li class="to_buy_1"><a href="javascript:void(0)" onClick="document.getElementById('light').style.display='block';document.getElementById('fade').style.display='block'">出价竞拍</a></li>
					<li class="to_buy_2"><a href="javascript:void(0)" onClick="document.getElementById('lightx').style.display='block';document.getElementById('fadex').style.display='block'">预约出价</a></li>
                    <%if Bidorbuy<>"" then response.Write "<li class=""to_buy_3""><a href=""javascript:form.action='/auctions/"&AuctionID&".html?s=c';form.submit()"" class='zhi'>直接购买</a></li>"%>
					<li class="to_buy_4"><a href="javascript:form.action='/auctions/<%=AuctionID%>.html?s=y';form.submit()">收藏</a></li>
                    
                    <input type="hidden" name="pic" value="<%=Image1%>" />
  <input type="hidden" name="Itemnumber" value="<%=AuctionID%>" />
  <input type="hidden" name="Bidorbuy" value="<%=Bidorbuy%>" />
  <input type="hidden" name="price" value="<%=Price%>" />
  <input type="hidden" name="Bids" value="<%=Bids%>" />
  <input type="hidden" name="Endtime" value="<%=dateadd("h",-1,replace(replace(EndTime,"+09:00",""),"T"," "))%>" />
  <input type="hidden" name="title" value="<%=Title%>" />
  <input type="hidden" name="website" value="<%=link%>" />
  <input type="hidden" name="url" value="<%=AuctionItemUrl%>" />
                    
                    
                    
				</ul>
			</div>
            </form>
			<div class="clear10"></div>
			<div class="dg_tip_2 f_l">
				<h4 class="h4_1">温馨提醒</h4>
				<ul>
					<li>您当前的账户余额是<font class="red">210</font>元，相当<font class="red">3000</font>日币，所以您最高可以出价到<font class="red">3000</font>日币进行竞拍。</li>
					<li>对超大、超重的物品，请先了解我们的物流说明或咨询日本客服，以免因误解而给您造成损失！</li>
					<li>拍收藏品的会员,特别是拍瓷器类的会员,我们对货品的真假不作担保,请在下标之前充分确认！一旦您出价成功，将不能取消。</li>
					<li>打火机、食品、活的生物、动物相关制品、带锂电池的手机等电器请不要拍，寄不回去，如果强行拍下造成的损失请自负。</li>
					<li>其它日语不明之处，请咨询我们客服。</li>
				</ul>
			</div>
			<div class="dg_tip_3 f_l">
				<h4 class="h4_1">名词解释</h4>
				<ul>
					<li><a href="">出价竞拍</a></li>
					<li><a href="">出价竞拍</a></li>
					<li><a href="">预约下标</a></li>
					<li><a href="">预约下标</a></li>
					<li><a href="">直接购买</a></li>
					<li><a href="">直接购买</a></li>
				</ul>
			</div>
		</div>
		<div class="pro_d_r">
			<h2 class="jp_h2_1">卖家信息</h2>
			<dl class="shop_info">
				<dd><span class="span_l">卖家雅虎账号：</span><%=SellerID%> </dd>
				<dd><span class="span_l">卖家评价： </span>好：+<%=TotalGoodRating%>  <img src="/images/good.jpg" /></dd>
				<dd><span class="span_l"> </span>差：-<%=TotalBadRating%>  <img src="/images/bad.jpg" /></dd>
				<dd><span class="span_l">卖家发货地址：</span><%=Location%></dd>
                <dd><a target="_blank" href="<%=AuctionItemUrl%>">预览Yahoo！拍卖</a></dd>
				<dd><span class="span_l">该卖家的其他拍品:</span></dd>
			</dl>
			<div class="other_pro">
				<h3>YAHOO竞拍</h3>
				<div id="demo_up">
					<div id=demo_up1>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_2.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_3.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_2.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_3.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_2.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_3.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_2.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_3.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
						<dl>
							<dt><img src="/images/other_1.jpg"></dt>
							<dd>现在价格：500元30分</dd>
						</dl>
					</div>
					<div id=demo_up2></div>
				</div>
				
				<script>
				var speed=40
				demo_up2.innerHTML=demo_up1.innerHTML
				function Marquee(){
					if(demo_up2.offsetTop-demo_up.scrollTop<=0)
						demo_up.scrollTop-=demo_up1.offsetHeight
					else{
						demo_up.scrollTop++
					}
				}
				var MyMar=setInterval(Marquee,speed)

				var flag = 0;

				function stop() {
					clearInterval(MyMar);
					flag = 1;
				}
				function start() {
					if(flag==1){
						MyMar=setInterval(Marquee,speed);
						flag = 0;
					}
				}

				//demo_up.onmouseover = stop();
				//demo_up.onmouseout = start();
				</script>
				<div class="clear"></div>
				<a href="javascript:avoid(0);" onclick="stop();" class="stop">暂停</a>
				<a href="javascript:avoid(0);" onclick="start();" class="start">开始</a>
			</div>
		</div>
		
		<div class="clear20"></div>
		
		<div class="reg_box reg_s_1 pro_tab">
			<ul class="tab_menu">
				<li class="current">商品详细</li>
				<li>出价记录</li>
                <li><a style="color:#777" target="_blank" href="http://translate.google.cn/translate?hl=zh-CN&ie=UTF8&prev=_t&sl=ja&tl=zh-CN&u=<%=Geturl%>/auctions/<%=AuctionID%>.html?s=t">中文翻译参考 </a></li>
			</ul>
			
			<div class="tab_box">
				<div>
					<div class="clear20"></div>
					<div class="pro_editor">
						<%=Description%>
					</div>
					<h2 class="jp_h2_1">支付说明</h2>
					<div class="clear20"></div>
					<div class="pro_editor">
						<p>

						是否支持信用开支付： <%if IsCreditCard="true" then response.Write "是" else response.Write "否"%> &nbsp; ; &nbsp; &nbsp; 是否支持银行转账：<%if IsNetBank="true" then response.Write "是" else response.Write "否"%>
						</p>
                        <p><%=Bank%></p>
                        <p>&nbsp;</p>
						
					</div>

					
				</div>	
					
				<div class="hide">
                <div class="clear20"></div>
					<p><%=Bidderlist%></p>
					<div class="clear20"></div>
					
                    
				</div>				
			</div>
			
			<div class="clear20"></div>
		</div>	
	</div>
</div>










<div id="light" class="pop_contentx">
<table width="100%" border="0" cellspacing="5" cellpadding="0">
<form name="formreg" method="post" action="" onSubmit="return myjobchk();">
  <tr>
    <td align="center"><strong>出价竞拍</strong></td>
    </tr>
  <tr>
    <td style="font-size:12px; color:red; background-color:#FFC; padding-left:15px">
	
	1.出价竞拍：结束之前出价最高者得。<br>
2.可以输入您的心理最高价位，系统每次只会小幅加价。<br>
3.出价需谨慎，一旦出价不可取消！ 
	
	</td>
    </tr>
  <tr>
    <td align="center" style="width:100px"><%=cdbl(Price)+cdbl(BidderPriceMoney)%>日元(约<%=(cdbl(Price)+cdbl(BidderPriceMoney))*web_rate%>RMB)以上可以出价竞拍</td>
    </tr>
  <tr>
    <td align="center">出价金额
      <input type="text" name="BidsPrice" value="<%=cdbl(Price)+cdbl(BidderPriceMoney)%>" /> 
      日元  <div id="dui" style="color:#F60"></div></td>
    </tr>
  <tr>
    <td align="center">
   
      <input type="submit" name="button" class="subtm" value="确认" />
    <a href = "javascript:void(0)" onclick = "document.getElementById('light').style.display='none';document.getElementById('fade').style.display='none'">关闭</a>
    
    <input type="hidden" name="pic" value="<%=Image1%>" />
  <input type="hidden" name="Itemnumber" value="<%=AuctionID%>" />
  <input type="hidden" name="price" value="<%=Price%>" />
  <input type="hidden" name="Endtime" value="<%=dateadd("h",-1,replace(replace(EndTime,"+09:00",""),"T"," "))%>" />
  <input type="hidden" name="title" value="<%=Title%>" />
  <input type="hidden" name="url" value="<%=AuctionItemUrl%>" />
  <input type="hidden" name="s" value="0" />
    </td>
    </tr>
    </form>
  </table>
</div> 
<div id="fade" class="pop_bgx"></div> 







<div id="lightx" class="pop_contentx">
<table width="100%" border="0" cellspacing="5" cellpadding="0">
<form name="formreg" method="post" action="" onSubmit="return myjobchk();">
  <tr>
    <td align="center"><strong>出价竞拍</strong></td>
    </tr>
  <tr>
    <td style="font-size:12px; color:red; background-color:#FFC; padding-left:15px">
	
	1.出价竞拍：结束之前出价最高者得。<br>
2.可以输入您的心理最高价位，系统每次只会小幅加价。<br>
3.出价需谨慎，一旦出价不可取消！ 
	
	</td>
    </tr>
  <tr>
    <td align="center" style="width:100px"><%=cdbl(Price)+cdbl(BidderPriceMoney)%>日元(约<%=(cdbl(Price)+cdbl(BidderPriceMoney))*web_rate%>RMB)以上可以出价竞拍</td>
    </tr>
  <tr>
    <td align="center">出价金额
      <input type="text" name="BidsPrice" value="<%=cdbl(Price)+cdbl(BidderPriceMoney)%>" /> 
      日元  <div id="dui" style="color:#F60"></div></td>
    </tr>
  <tr>
    <td align="center">
   
      <input type="submit" name="button" class="subtm" value="确认" />
    <a href = "javascript:void(0)" onclick = "document.getElementById('lightx').style.display='none';document.getElementById('fadex').style.display='none'">关闭</a>
    
    <input type="hidden" name="pic" value="<%=Image1%>" />
  <input type="hidden" name="Itemnumber" value="<%=AuctionID%>" />
  <input type="hidden" name="price" value="<%=Price%>" />
  <input type="hidden" name="Endtime" value="<%=dateadd("h",-1,replace(replace(EndTime,"+09:00",""),"T"," "))%>" />
  <input type="hidden" name="title" value="<%=Title%>" />
  <input type="hidden" name="url" value="<%=AuctionItemUrl%>" />
  <input type="hidden" name="s" value="1" />
    </td>
    </tr>
    </form>
  </table>
</div> 
<div id="fadex" class="pop_bgx"></div> 











<%end if%>


<div class="clear"></div>

<!--#include file="../../common/footerauctions.asp"-->








<%
'竞拍
if request.Form("s")="0" or request.Form("s")="1" then
  uid=checkstr(inHTML(request.cookies("u")("uID")))
  Itemnumber=checkstr(inHTML(Request("Itemnumber")))
  title=checkstr(inHTML(Request("title")))
  pic=checkstr(inHTML(Request("pic")))
  url=checkstr(inHTML(Request("url")))
  Endtime=checkstr(inHTML(Request("Endtime")))
  price=checkstr(inHTML(Request("price")))
  BidsPrice=checkstr(inHTML(Request("BidsPrice")))
  if request.Form("s")="0" then typeid=0 else typeid=1
  
  if uid="" then
  session("returnurl")="/auctions/"&AuctionID&".html?s=t"
  response.Write "<div class=""pop_content"">请先登录会员再出价，<a href='/login'>立即登录</a></div><div class=""pop_bg""></div>"
  response.end
  end if
  
  '判断出价
  if BidsPrice="" then
  response.Write "<div class=""pop_content"">出价不能为空, <a href=""javascript:history.back(-1)"">返回</a></div><div class=""pop_bg""></div>"
  response.end
  end if
  '判断出价是否正确
  if cdbl(BidsPrice)<cdbl(price) then
  response.Write "<div class=""pop_content"">您的出价过低, <a href=""javascript:history.back(-1)"">返回</a></div><div class=""pop_bg""></div>"
  response.end
  end if
  
  '保证金计算
  bailMoney=cdbl(BidsPrice)*web_rate*0.3
  if bailMoney<100 then bailMoney=100

  '商品写入
  set rsx=server.createobject("adodb.recordset")
  sql="select * from AuctionsOrder where uid='"&uid&"' and Itemnumber='"&Itemnumber&"'"
  rsx.open sql,conn,1,3
  if not rsx.eof then
  rsx("BidsPrice")=BidsPrice
  rsx.update
  if typeid="0" then
  
  '系统出价
  keypostdatastrx="auctionUrl="&replace(AuctionItemUrl,"http://","")&"&big="&BidsPrice&"&cookie="&server.urlencode(replace(web_cookie,"=","zibolan"))&"&rp=zibolan"
  keytopurlx=web_bidsUrl&"?"
  keyREST_RESPONSEtt=getHTTPPage(keytopurlx&keypostdatastrx)
  
  response.Write "<div class=""pop_content"">出价成功<br><a href='/user/auctions/0'>进入出价竞拍</a> &nbsp; <a href='/auctions/"&AuctionID&".html?s=t'>关闭</a></div><div class=""pop_bg""></div>"
  else
  response.Write "<div class=""pop_content"">出价成功<br><a href='/user/auctions/1'>进入预约出价</a> &nbsp; <a href=""javascript:history.back(-1)"">关闭</a></div><div class=""pop_bg""></div>"
  end if
  response.end
  rsx.close
  set rsx=nothing
  else
  
  
  '判断是否有存入信用保证金
  set rss=conn.execute("select CreditMargin,money from [user] where uid='"&uid&"'")
    rssCreditMargin=rss("CreditMargin") '信用保证金
	rssmoney=rss("money") '账户余额
  set rss=nothing
  
  if (cdbl(rssCreditMargin)-cdbl(web_CreditMargin))<0 then

	  '判断余额是否满足
	  if (cdbl(rssmoney)-cdbl(bailMoney))<0 then
	  response.Write "<div class=""pop_content"">余额不足，<a href=""javascript:adClick('/user/money/recharge', '/auctions/"&Itemnumber&".html?s=t');"">去充值</a></div><div class=""pop_bg""></div>"
	  response.end 
	  end if
	  
	  '扣除余额
	  conn.execute("update [user] set money=money-"&cdbl(bailMoney)&" where uid='"&uid&"'") 
	  
	  '写入资金明细
	  set rsx=server.createobject("adodb.recordset")
	  sql="select * from funds" 
	  rsx.open sql,conn,1,3
	  rsx.addnew  
	  rsx("Uid")=uid
	  rsx("money")="-"&bailMoney
	  rsx("Balance")=cdbl(rssmoney)-cdbl(bailMoney) '当前账户余额减去竞拍预存款
	  rsx("content")=Itemnumber&"竞拍预付款"
	  rsx("Type")=1 '消费
	  rsx("PayType")=2 '系统操作
	  rsx("mark")=1
	  rsx.update
	  rsx.close
	  set rsx=nothing
	  
	  
  
  else
      bailMoney=0  '如果信用保证金满足就设置竞拍预付款为0
  end if
  
  
  rsx.addnew
  rsx("uid")=uid
  rsx("Itemnumber")=Itemnumber
  rsx("SellerID")=SellerID
  rsx("Endtime")=Endtime
  rsx("title")=title
  rsx("pic")=pic
  rsx("url")=url
  rsx("price")=price
  rsx("BidsPrice")=BidsPrice
  rsx("bail")=bailMoney
  rsx("type")=typeid
  if typeid="0" then rsx("bidmark")=2 else rsx("bidmark")=1 '已出价
  rsx.update

  if typeid="0" then

  '系统出价
  keypostdatastrx="auctionUrl="&replace(AuctionItemUrl,"http://","")&"&big="&BidsPrice&"&cookie="&server.urlencode(replace(web_cookie,"=","zibolan"))&"&rp=zibolan"
  keytopurlx=web_bidsUrl&"?"
  keyREST_RESPONSEtt=getHTTPPage(keytopurlx&keypostdatastrx)

  response.Write "<div class=""pop_content"">出价成功<br><a href='/user/auctions/0'>进入出价竞拍</a> &nbsp; <a href='/auctions/"&AuctionID&".html?s=t'>关闭</a></div><div class=""pop_bg""></div>"
  else
  response.Write "<div class=""pop_content"">出价成功<br><a href='/user/auctions/1'>进入预约出价</a> &nbsp; <a href=""javascript:history.back(-1)"">关闭</a></div><div class=""pop_bg""></div>"
  end if
  response.end
  rsx.close
  set rsx=nothing
  end if
end if





'加入购物车
if request.QueryString("s")="c" then
  order=checkstr(inHTML(request.cookies("order")))
  Itemnumber=checkstr(inHTML(Request("Itemnumber")))
  title=checkstr(inHTML(Request("title")))
  pic=checkstr(inHTML(Request("pic")))
  url=checkstr(inHTML(Request("url")))
  Bidorbuy=checkstr(inHTML(Request("Bidorbuy")))
  Qty=checkstr(inHTML(Request("Qty")))
  content=checkstr(inHTML(Request("content")))
  
  if Qty="" or not isnumeric(Qty) then Qty=1

  set rsx=server.createobject("adodb.recordset")
  sql="select * from cart where Itemnumber='"&Itemnumber&"' and [order]='"&order&"'"
  rsx.open sql,conn,1,3
  if not rsx.eof then
  rsx("Qty")=rsx("Qty")+Qty
  rsx("content")=content
  rsx.update
  response.Write "<div class=""pop_content"">加入成功<br><a href='/cart'>进入购物车</a> &nbsp; <a href=""javascript:history.back(-1)"">关闭</a></div><div class=""pop_bg""></div>"
  response.end
  rsx.close
  set rsx=nothing
  else
  rsx.addnew
  rsx("Itemnumber")=Itemnumber
  rsx("order")=order
  rsx("title")=title
  rsx("pic")=pic
  rsx("url")=url
  rsx("price")=Bidorbuy
  rsx("Qty")=Qty
  rsx("content")=content
  rsx.update
  response.Write "<div class=""pop_content"">加入成功<br><a href='/cart'>进入购物车</a> &nbsp; <a href=""javascript:history.back(-1)"">关闭</a></div><div class=""pop_bg""></div>"
  response.end
  rsx.close
  set rsx=nothing
  end if
end if



'加为收藏
if request.QueryString("s")="y" then
  pic=checkstr(inHTML(Request("pic")))
  Itemnumber=checkstr(inHTML(Request("Itemnumber")))
  Bidorbuy=checkstr(inHTML(Request("Bidorbuy")))
  price=checkstr(inHTML(Request("price")))
  Bids=checkstr(inHTML(Request("Bids")))
  Endtime=checkstr(inHTML(Request("Endtime")))
  title=checkstr(inHTML(Request("title")))
  website=checkstr(inHTML(Request("website")))
  uid=checkstr(inHTML(request.cookies("u")("ID")))
  
  if uid="" then
  session("returnurl")="/auctions/"&AuctionID&".html?s=t"
  response.Write "<div class=""pop_content"">请先登录会员再收藏，<a href='/login'>立即登录</a></div><div class=""pop_bg""></div>"
  response.end
  end if

  set rsx=server.createobject("adodb.recordset")
  sql="select * from collect where Itemnumber='"&Itemnumber&"' and uid="&uid&" and website='"&website&"'"
  rsx.open sql,conn,1,3
  if not rsx.eof then
  response.Write "<div class=""pop_content"">您已经收藏过该商品<br><a href='/user/collect/daipai'>进入收藏夹</a> &nbsp; <a href=""javascript:history.back(-1)"">返回</a></div><div class=""pop_bg""></div>"
  response.end
  else
  rsx.addnew
  rsx("pic")=pic
  rsx("Itemnumber")=Itemnumber
  if Bidorbuy<>"" then rsx("Bidorbuy")=Bidorbuy
  rsx("price")=price
  rsx("Bids")=Bids
  rsx("Endtime")=Endtime
  rsx("title")=title
  rsx("website")=website
  rsx("uid")=uid
  rsx.update
  response.Write "<div class=""pop_content"">收藏成功<br><a href='/user/collect/daipai'>进入收藏夹</a> &nbsp; <a href=""javascript:history.back(-1)"">关闭</a></div><div class=""pop_bg""></div>"
  response.end
  rsx.close
  set rsx=nothing
  end if
end if
%>



</body>
</html>